import LayoutView from "@/layout/LayoutView.vue";

// 登录认证
const AccountRouter = () => import("@/views/account/AccountRouter.vue");
const LoginPage = () => import("@/views/account/login/LoginPage.vue");
const ForgetPage = () => import("@/views/account/forget/ForgetPage.vue");
const LockPage = () => import("@/views/account/lock/LockPage.vue");
const RedirectPage = () => import("@/views/account/redirect/RedirectPage.vue");
const RegisterPage = () => import("@/views/account/register/RegisterPage.vue");

// 欢迎页
const WelPage = () => import("@/views/admin/wel/WelPage.vue");

// 个人中心
const PersonalPage = () => import("@/views/admin/personal/PersonalPage.vue");
const SettingPage = () => import("@/views/admin/setting/SettingPage.vue");

// demo演示页
const TinymcePage = () => import("@/views/demo/tinymce/TinymcePage.vue");
const TablePage = () => import("@/views/demo/table/TablePage.vue");

// error
const Error403 = () => import("@/views/error/ErrorPage403.vue");
const Error404 = () => import("@/views/error/ErrorPage404.vue");
const Error500 = () => import("@/views/error/ErrorPage500.vue");
const ErrorBlank = () => import("@/views/error/ErrorBlank.vue");
const ErrorDeveloping = () => import("@/views/error/ErrorDeveloping.vue");
const ErrorNewWindow = () => import("@/views/error/ErrorNewWindow.vue");

const allComponent = new Map();

allComponent.set("LayoutView", LayoutView); // 路由容器

allComponent.set("AccountRouter", AccountRouter); // 登录页
allComponent.set("LoginPage", LoginPage); // 登录页
allComponent.set("ForgetPage", ForgetPage); // 登录页
allComponent.set("LockPage", LockPage); // 登录页
allComponent.set("RedirectPage", RedirectPage); // 登录页
allComponent.set("RegisterPage", RegisterPage); // 登录页

allComponent.set("WelPage", WelPage); // 欢迎页
allComponent.set("PersonalPage", PersonalPage); // 个人中心
allComponent.set("SettingPage", SettingPage); // 个人设置

// 错误页
allComponent.set("ErrorRouter", LayoutView); // 后台管理
allComponent.set("ErrorBlank", ErrorBlank); // 空白页
allComponent.set("Error403", Error403); // 页面未授权
allComponent.set("Error404", Error404); // 页面不存在
allComponent.set("Error500", Error500); // 系统错误
allComponent.set("ErrorDeveloping", ErrorDeveloping); // 开发中
allComponent.set("ErrorNewWindow", ErrorNewWindow); // 新窗口打开

// demo
allComponent.set("TinymcePage", TinymcePage); // 富文本
allComponent.set("TablePage", TablePage); // 表格

export { allComponent };
